package cn.com.yinhex.as.util;

public class SafeHtml
{
	public static String[] badtagnames = "script;style;object;param;applet;area;base;body;form;head;meta;html;input;map;option;select;marquee;textarea;basefont;frame;frameset;iframe;noframes;noscript"
			.split(";");

	public static final String covertHtml(String content)
	{
		for (int i = 0; i < badtagnames.length; i++)
		{
			if (content.indexOf("<" + badtagnames[i]) > -1)
			{
				content = StringUtil.replaceAll(content, "<\\/*"
						+ badtagnames[i] + "[^>]*>", "");
			}
		}
		return content;
	}
}
